package com.wwwarehouse.contract.bean;

import android.os.Parcel;
import android.os.Parcelable;
import android.support.v4.view.ViewPager;

import java.util.ArrayList;

/**
 * Created by ShineF on 2017/9/7 0007.
 */

public class GetShopIdBean implements Parcelable {

    /**
     * total : 58
     * size : 9
     * page : 4
     * list : [{"shopName":"测试店铺3","shopIcon":"","shopId":520075000614001,"status":0},{"shopName":"测试店铺125","shopIcon":"","shopId":520075000615002,"status":0},{"shopName":"测试店铺4","shopIcon":"","shopId":520075000615003,"status":0},{"shopName":"测试店铺135","shopIcon":"","shopId":520075000615005,"status":0},{"shopName":"测试1店铺135","shopIcon":"","shopId":52007500615005,"status":0},{"shopName":"测试店铺4","shopIcon":"","shopId":520075000615006,"status":0},{"shopName":"测试1店铺4","shopIcon":"","shopId":52007500615006,"status":0},{"shopName":"测试店铺4","shopIcon":"","shopId":520075000615009,"status":0},{"shopName":"测试12店铺4","shopIcon":"","shopId":52007500615009,"status":0}]
     */

    private int total;
    private int size;
    private int page;
    private ArrayList<ListBean> list;

    public int getTotal() {
        return total;
    }

    public void setTotal(int total) {
        this.total = total;
    }

    public int getSize() {
        return size;
    }

    public void setSize(int size) {
        this.size = size;
    }

    public int getPage() {
        return page;
    }

    public void setPage(int page) {
        this.page = page;
    }

    public ArrayList<ListBean> getList() {
        return list;
    }

    public void setList(ArrayList<ListBean> list) {
        this.list = list;
    }

    public static class ListBean implements Parcelable {
        /**
         * shopName : 测试店铺3
         * shopIcon :
         * shopId : 520075000614001
         * status : 0
         */

        private String shopName;
        private String shopIcon;
        private long shopId;
        private int status;

        public String getShopName() {
            return shopName;
        }

        public void setShopName(String shopName) {
            this.shopName = shopName;
        }

        public String getShopIcon() {
            return shopIcon;
        }

        public void setShopIcon(String shopIcon) {
            this.shopIcon = shopIcon;
        }

        public long getShopId() {
            return shopId;
        }

        public void setShopId(long shopId) {
            this.shopId = shopId;
        }

        public int getStatus() {
            return status;
        }

        public void setStatus(int status) {
            this.status = status;
        }

        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeString(this.shopName);
            dest.writeString(this.shopIcon);
            dest.writeLong(this.shopId);
            dest.writeInt(this.status);
        }

        public ListBean() {
        }

        protected ListBean(Parcel in) {
            this.shopName = in.readString();
            this.shopIcon = in.readString();
            this.shopId = in.readLong();
            this.status = in.readInt();
        }

        public static final Creator<ListBean> CREATOR = new Creator<ListBean>() {
            @Override
            public ListBean createFromParcel(Parcel source) {
                return new ListBean(source);
            }

            @Override
            public ListBean[] newArray(int size) {
                return new ListBean[size];
            }
        };
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeInt(this.total);
        dest.writeInt(this.size);
        dest.writeInt(this.page);
        dest.writeList(this.list);
    }

    public GetShopIdBean() {
    }

    protected GetShopIdBean(Parcel in) {
        this.total = in.readInt();
        this.size = in.readInt();
        this.page = in.readInt();
        this.list = new ArrayList<ListBean>();
        in.readList(this.list, ListBean.class.getClassLoader());
    }

    public static final Parcelable.Creator<GetShopIdBean> CREATOR = new Parcelable.Creator<GetShopIdBean>() {
        @Override
        public GetShopIdBean createFromParcel(Parcel source) {
            return new GetShopIdBean(source);
        }

        @Override
        public GetShopIdBean[] newArray(int size) {
            return new GetShopIdBean[size];
        }
    };
}
